MPIRUN = mpiexec
MPIRUN += --allow-run-as-root
HOSTFILE = hosts
NUMPROCESS = 3

# EXPATH = /root/hzh/exp3

# REMOTE = 

build_hello:
	mpicc hello_c.c -o hello_c

# sync:
# 	@rsync -avz ./ os02:$(EXPATH)
# 	@rsync -avz ./ os03:$(EXPATH)

run1:
	$(MPIRUN) -np $(NUMPROCESS) ./hello_c

run2:
# 这个坑是,相同路径之下必须要有相同的文件
	$(MPIRUN) -hostfile $(HOSTFILE) -np $(NUMPROCESS) ./hello_c

run3:
	$(MPIRUN) -hostfile $(HOSTFILE) -np $(NUMPROCESS) vector_count